package com.xdcplus.web.common.enums.base;

/**
 * 产品状态
 * @author Fish.Fei
 */

public enum BaseMdlStatusEnum {
    DRAFT("DRAFT", "草稿"),
    RELEASE("RELEASE", "放行"),
    INVALID("INVALID", "作废"),
    ;

    private String code;

    private String msg;

    public static String getMsg(String code) {
        for (BaseMdlStatusEnum ele : values()) {
            if(ele.getCode().equals(code)) {return ele.getMsg();}
        }
        return null;
    }

    BaseMdlStatusEnum(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

}
